<%@ page language="java" pageEncoding="utf-8"
         contentType="text/html;charset=utf-8" %>
<html>

<%@ include file="../../../common/jstl.jsp" %>


<head>
</head>

<body>


<div id="addForm" class="mgt40">
    <form action="${ctx}${url}" id="editForm" method="post">
        <input type="hidden" name="id" value="${id}"/>
        <%--<div class="t_text w200 ml10">--%>
        <textarea name="text" class="J_toolsBar fl" style="width:580px;height:250px;" maxlength="400" placeholder="最多400字"></textarea>
        <%--<input type="text" name="text" class="t_text w200 ml10" style="width: 400px;height: 400px">--%>
        <%--<textarea type="text" name="text"  maxlength="300"/>--%>
        <%--</div>--%>
    </form>

</div>
<script>
    $('#editForm').validator({
        valid: function (form) {
            var laodIdx = layer.load();
            $('#editForm').ajaxSubmit({
                data: {},
                traditional: true,
                success: function (result) {
                    layer.close(laodIdx);
                    if (result.success) {
                        layer.alert('操作成功', function () {
                            window.location.reload();
                        });
                    } else {
                        layer.alert(result.msg);
                    }
                }
            });
        }
    });
</script>

</body>
</html>